package com.victor.entity;

import java.io.Serializable;
import java.util.List;
import java.util.Map;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Transient;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

@Entity
@Table(name = "user")
@Data
@NoArgsConstructor
@AllArgsConstructor
public class User implements Serializable {

	private static final long serialVersionUID = 1L;

	@Id
	@GeneratedValue(strategy = GenerationType.IDENTITY) // 主键类型--自动递增生成
	@Column(name = "id", unique = true, nullable = false, length = 11)
	private Integer id;// 编号,

	@Column(name = "nickname", length = 50)
	private String nickname;// 昵称,

	@Column(name = "name", length = 50)
	private String name;// 姓名,

	@Column(name = "mailbox", length = 50)
	private String mailbox;// 邮箱

	@Column(name = "idcard", length = 50)
	private String idcard;// 身份证

	@Column(name = "phone", length = 50)
	private String phone;// 手机号
	
	@Column(name = "account", length = 50)
	private String account;//账号,

	@Column(name = "password", length = 50)
	private String password;// 密码,

	@Column(name = "paypassword", length = 50)
	private String paypassword;// 支付密码

	@Column(name = "wechat", length = 50)
	private String wechat;// 微信名,

	@Column(name = "openid", length = 50)
	private String openid;// 微信openid,

	@Column(name = "qqname", length = 50)
	private String qqname;// QQ名称,

	@Column(name = "qqopenid", length = 50)
	private String qqopenid;// QQopenid,

	@Column(name = "bankcard", length = 50)
	private String bankcard;// 银行卡号,

	@Column(name = "zhucedata", length = 50)
	private String zhucedata;// 注册日期,

	@Column(name = "idcard_front", length = 50)
	private String idcard_front;// 身份证正面

	@Column(name = "idcard_back", length = 50)
	private String idcard_back;// 身份证反面

	@Column(name = "idcard_hold", length = 50)
	private String idcard_hold;// 手持身份证

	@Column(name = "headphoto", length = 500)
	private String headphoto;// 用户头像

	@Column(name = "frozen", length = 50, columnDefinition = "INT default 0")
	private String frozen;// 是否冻结标志 0.正常 1.冻结

	@Column(name = "frozen_starttime", length = 50)
	private String frozen_starttime;// 冻结起始时间

	@Column(name = "frozen_endtime", length = 50)
	private String frozen_endtime;// 冻结终止时间

	@Column(name = "integral", length = 50)
	private String integral; // 积分

	@Column(name = "idcard_validdate", length = 50)
	private String idcard_validdate;// 身份证有效期

	@Column(name = "idcard_address", length = 50)
	private String idcard_address; // 身份证地址
	
	@Column(name="question1",length=50)
	private String question1;//问题1
	
	@Column(name="question2",length=50)
	private String question2;//问题2
	
	@Column(name="question3",length=50)
	private String question3;//问题3
	
	@Column(name="answer1",length=50)
	private String answer1;//回答1
	
	@Column(name="answer2",length=50)
	private String answer2;//回答2
	
	@Column(name="answer3",length=50)
	private String answer3;//回答3

	@Transient
	private List<Personaltravel> personaltravels;

	@Transient
	private List<UserBankcard> userBankcards;// 用户绑定多张银行卡

	@Transient
	private String focuscount;// 关注数量

	@Transient
	private String fscount;// 粉丝数量

	@Transient
	private String praisecount;// 点赞数量

	@Transient
	private String iffocus;// 是否点赞 0-没有 1-点赞了

	@Transient
	private Integer sms_if_success;// 沉睡用户短信是否发送成功标志 0 失败  1成功
	
	@Transient
	private Map userAdd;

}
